package it.pecuswap.backend.business;

import it.pecuswap.backend.delegate.ConfigurazioneDelegate;
import it.pecuswap.backend.entities.Config;

import java.util.List;
import java.util.Properties;

public class ConfigurazioneBusiness {

	public Properties getProperties() {
		
			Properties props = new Properties();

			ConfigurazioneDelegate delegate = new ConfigurazioneDelegate(Config.class, false);
			List<Config> configs = delegate.findAll();
			
			for (Config c : configs){
				props.put(c.getKeyConfig(), c.getValueConfig());
			}
			
			return props;
	}

}
